# -*- coding: utf-8 -*-
"""
Module Description: 接口基类
Date:2017/12/22
Anchor:Bai Jin Ping
"""
# from pyshare.framework.firefly_dc.globalobject import GlobalObject
# from pyshare.framework.sched.executor import executor_adapter
from framework.firefly_dc.globalobject import GlobalObject


def do_when_stop():
    """
    服务进程关闭前的处理(业务相关)
    """
    # 关闭定时任务
    # executor_adapter.Worker.rest()


GlobalObject.stophandler = staticmethod(do_when_stop)


# 加载frontend接口
from framework.router import webservice

# 加载area接口
from app.user import load as load_area
load_area.load_modules()


# 加载admin接口
# from app.admin import load as load_admin
# load_admin.load_modules()


# 加载sched
# from app.middlewares.sched import load
# load.load_modules()
